/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package aso.upna.controllers.chains;

import aso.upna.cancion.AbstractCancion;
import aso.upna.playlist.GenericList;

/**
 *
 * @author triki
 */
public class RemoteChain extends AbstractChain {

    private GenericList lista;

    public RemoteChain(GenericList lista)
    {
        super();
        this.lista = lista;
    }

    @Override
    public void sendToChain(AbstractCancion cancion) {

        if(!cancion.is_local())
            lista.addElement(cancion);
        else
            cad.sendToChain(cancion);
    }

}
